﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Cld-List.ascx.cs" Inherits="Classified_UserControls_Cld_List" %>
<style>
#ContentPlaceHolder1_ContentPlaceHolder_SubMaster_adList1_upMain{padding:5px;}
.adcolor{color:#00947B;}
</style>

<asp:UpdatePanel ID="upMain" runat="server"   UpdateMode="Conditional" >
<ContentTemplate>
    <div class="noumberbox">    <% if (ViewState["TotalAds"] != null)
       {%>

    	   		 <p class="fl">Total:  <%=Convert.ToString(ViewState["TotalAds"])%> items</p>
                 <%} %>

        <div class="numbering">
        	<ul id="ulPageing" runat="server"> 
             </ul>
        </div>
          <div class="clear"></div>	
          <div class="emptyRepeatermessage hide" id="divEmptyMessage" runat="server" >
          <asp:Label ID="lblEmptyMessage" runat="server" Text="Sorry no Ads found. You can go to <a href='/Classified/Cld-Home.aspx'>Home Page</a> "></asp:Label></div>
    </div>
    
        
         <asp:Repeater ID="rptAdList" runat="server" 
            onitemdatabound="rptAdList_ItemDataBound">
         <ItemTemplate>
            <div id="divFeatured" runat="server" class="clear" ></div>
         <div id="divFeaturedImg" runat="server" class="featured"><img src='/Classified/images/featured.png' height="77" width="76" border="0"></div>
        <div class="product_row bgwite">
        	<div class="product_col_l">
            	<div class="porduct_img"><asp:Image ID="imgAdImage" runat="server" ImageUrl='<%# Eval("ImagePath") %>' border="0" /></div>
                <div class="porduct_details">
         <asp:Label ID="lblAdID" runat="server" Text='<%# Eval("AdID")%>' Visible="false"></asp:Label>
         <asp:Label ID="lblIsActive" runat="server" Text='<%# Eval("IsActive")%>' Visible="false"></asp:Label>
                	<h3><a href="Cld-Ad-Details.aspx?AdID=<%# Eval("AdID")%>" class="adcolor"><%# Eval("AdTitle")%></a></h3>
                    <p><%# Eval("ProdDesc")%></p>
                    <p class="fl"><a href="#">
                    
                    <%--<img src='<%# Eval("MemberShipType") %>' height="39" width="39" border="0" alt="" />--%>
                    <img src='/Classified/images/gold.png' height="39" width="39" border="0" alt="" />
                    <asp:Label ID="lblFeaturedAdID" runat="server" Visible="false" Text='<%# Eval("FeaturedAd") %>'></asp:Label>   </a></p>
                    <p class="fl ml10px"><a href="#"><img src="/Classified/images/play.png" height="38" width="38" border="0"></a></p>
                
                     <p class="fr m5px"><a href="Cld-Ad-Details.aspx?AdID=<%# Eval("AdID")%>">
                     
                     <img src="/Classified/images/detail.jpg" height="30" width="100" border="0" alt=""/></a></p> 
                         <asp:Label ID="lblPostedBy" Text='<%# Eval("UserID") %>' Visible="false" runat="server"></asp:Label>
                         <p class="fr mt5px ml5px"><a href="Cld-Edit-Ad.aspx?AdID=<%# Eval("AdID")%>">
                     <asp:Image ID="imgEdit" ImageUrl="~/Classified/images/edit.jpg" runat="server" Visible="false"/>
                     </a>
                     </p>
                     <p class="fr mt5px">
                     <asp:ImageButton ID="imgDelete" ImageUrl="/Classified/images/delete.jpg" OnClick="imgDelete_Click" AlternateText="Delete"  runat="server" Visible="false"></asp:ImageButton></p>
                <p class="fr mt5px">
                     <asp:ImageButton ID="imgActivate" ImageUrl="/Classified/images/activate1.jpg" OnClick="imgAcitvate_Click" AlternateText="Activate"  runat="server" Visible="false"></asp:ImageButton></p>
                 </div>
            
            </div> 
        </div>
         </ItemTemplate>
         </asp:Repeater>
        
        
    <% if (ViewState["TotalAds"] != null)
    {%>

    <p class="fl">Total:  <%=Convert.ToString(ViewState["TotalAds"])%> items</p>
    <%} %>
    <div class="numbering">
    <ul id="ulBottomPaging" runat="server">
    </ul>
    </div>
    <div class="clear"></div>	
    
    
    </ContentTemplate></asp:UpdatePanel>